﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace MS_UI
{
    public partial class CIMFrm : Form
    {
        public CIMFrm()
        {
            InitializeComponent();
        }

        public string Cim_message;

        public string Interval_second_time; 

        


        public CIMFrm(string cim_message, string interval_second_time) 
        {
            InitializeComponent();

            this.Cim_message = cim_message;
            this.Interval_second_time = interval_second_time;
            if(Convert.ToInt16(Interval_second_time) > 0)
            {
                timer1.Enabled = true;
                timer1.Interval = Convert.ToInt16(Interval_second_time)*1000;
            }

        }

        private void CIMFrm_Load(object sender, EventArgs e)
        {
            richTextBox1.Text = Cim_message;
        }

        private void timer1_Tick(object sender, EventArgs e)
        {
            this.Close();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            this.Close();
        }
    }
}
